<!--
@ 作者: 阿拉丁矿工 黄传鸿 <hchhyzc@foxmail.com>
-->
<template>
  <div class="h_top_menu">
    <!-- 菜单-1.0_编辑-图元 -->
    <NTooltip placement="bottom" trigger="hover" v-for="SVGItem in editLine">
      <template #trigger>
        <svg class="h_svg_icon" v-if="!SVGItem.active" xmlns="http://www.w3.org/2000/svg"
          xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" width="36" height="36" viewBox="0 0 1024 1024"
          v-html="SVGItem.disable" @click.stop="menuStore.menuHandle(SVGItem.key)"></svg>
        <svg class="h_svg_icon" v-if="SVGItem.active" xmlns="http://www.w3.org/2000/svg"
          xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" width="36" height="36" viewBox="0 0 1024 1024"
          v-html="SVGItem.enabled" @click.stop="menuStore.menuHandle(SVGItem.key)"></svg>
      </template>
      <span>{{ SVGItem.label }}</span>
    </NTooltip>
  </div>
</template>

<script setup lang="ts">
/* ================================================================================================ */
//                                ★ 引入
/* ================================================================================================ */
import { reactive, ref, toRefs, computed, watch, nextTick, onMounted } from "vue";



/**~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
// 🐸 引入存储
/**~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
import { storeToRefs } from "pinia";
import { useMenuStore } from "@/store/menuStore"; // 菜单

/**~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
// 🐸 使用存储
/**~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
const menuStore = useMenuStore(); // 菜单
/** 解构存储*/
const { editLine } = storeToRefs(menuStore);

</script>

<style lang="scss" scoped>
/* 引入共用css */
@import "@/assets/h.scss";
</style>
